package cn.wh.executor.result;

import cn.wh.executor.resultset.DefaultResultSetHandler;
import cn.wh.session.ResultContext;

/**
 * @Author wh
 * @Description
 * @Date 2023/6/25 9:03
 * @Version 1.0
 **/
public class DefaultResultContext implements ResultContext {

    private Object resultObject;

    private int resultCount;


    public DefaultResultContext(){
        this.resultObject=null;
        this.resultCount=0;
    }



    @Override
    public Object getResultObject() {
        return resultObject;
    }

    @Override
    public int getResultCount() {
        return resultCount;
    }

    public void nextResultObject(Object resultObject){
        resultCount++;
        this.resultObject=resultObject;
    }



}
